import request from '@/utils/request'
import qs from 'qs'

export function list() {
    return request({
        url: '/api/banner/list.do',
        method: 'get'
    })
}

export function add(id, name, linkUrl, imageUrl) {
    return request({
        url: '/api/banner/add.do',
        method: 'post',
        data: qs.stringify({
            id, name, linkUrl, imageUrl
        })
    })
}

export function changeShow(id) {
    return request({
        url: '/api/banner/changeShow.do',
        method: 'get',
        params:{
            id
        }
    })
}


export function del(id) {
    return request({
        url: '/api/banner/delete.do',
        method: 'get',
        params:{
            id
        }
    })
}